package io.renren.modules.gengyun.feign;

import io.renren.common.Result;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.http.MediaType;
import org.springframework.web.bind.annotation.*;
import org.springframework.web.multipart.MultipartFile;

import java.util.Map;

@FeignClient("gengyun-upload")
public interface TestUploadFeignService {
    @RequestMapping(value="/tesT/start", method = RequestMethod.POST)
    public String starttesT(@RequestParam String canshu);

    @RequestMapping(value="/tesT/pause", method = RequestMethod.POST)
    public String starttesT2(@RequestParam String password,@RequestParam String name);

    @RequestMapping(value="/tesT/resume", method = RequestMethod.POST)
    public Map<Object,Object> starttesT3(@RequestBody Map<Object,Object> map);

    @RequestMapping(method = RequestMethod.POST, value = "/tesT/uploadFile",
            produces = {MediaType.APPLICATION_JSON_UTF8_VALUE},
            consumes = MediaType.MULTIPART_FORM_DATA_VALUE)
    public String uploadFile(@RequestPart(value = "file") MultipartFile file, @RequestParam(value = "fileType") String fileType);

}
